<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Postfix</title>
<link rel="stylesheet" type="text/css" href="../C.css">
<script type="text/javascript" src="../jquery.js"></script><script type="text/javascript" src="../jquery.syntax.js"></script><script type="text/javascript" src="../yelp.js"></script>
</head>
<body id="home">
<!--<script src="https://ssl.google-analytics.com/urchin.js" type="text/javascript"></script><script type="text/javascript">
        _uacct = "UA-1018242-8";
        urchinTracker();
      </script><script>
      function englishPageVersion() {
        var href = window.location.href;
        if (href.slice(-1) == "/") {
                window.location = "index.html.en";
        } else {
                window.location = href.replace(/\.html.*/, ".html.en");
        }
         return false;
      }
      function browserPreferredLanguage() {
        var href = window.location.href;
        if (href.slice(-1) == "/") {
                window.location = href;
        } else {
                window.location = href.replace(/\.html.*/, ".html");
        }
        return false;
      }
      </script>--><div id="container">
<div id="container-inner">
<div id="mothership"><ul>
<li><a href="https://partners.ubuntu.com">Partners</a></li>
<li><a href="https://www.ubuntu.com/support/community-support">Support</a></li>
<li><a href="https://community.ubuntu.com">Community</a></li>
<li><a href="https://www.ubuntu.com">Ubuntu.com</a></li>
</ul></div>
<div id="header">
<h1 id="ubuntu-header"><a href="https://help.ubuntu.com/">Ubuntu Documentation</a></h1>
<ul id="main-menu">
<li><a class="main-menu-item current" href="https://help.ubuntu.com/">Official Documentation</a></li>
<li><a href="https://help.ubuntu.com/community/CommunityHelpWiki">Community Help Wiki</a></li>
<li><a href="https://community.ubuntu.com/t/contribute/26">Contribute</a></li>
</ul>
</div>
<div id="menu-search"><div id="search-box">
<noscript><form action="https://www.google.com/cse" id="cse-search-box"><div>
<input type="hidden" name="cx" value="003883529982892832976:e2vwumte3fq"><input type="hidden" name="ie" value="UTF-8"><input type="text" name="q" size="21"><input type="submit" name="sa" value="Search">
</div></form></noscript><!--
<script>
                document.write('<form action="https://help.ubuntu.com/search.html" id="cse-search-box">');
                document.write('  <div>');
                document.write('    <input type="hidden" name="cof" value="FORID:9">');
                document.write('    <input type="hidden" name="cx" value="003883529982892832976:e2vwumte3fq">');
                document.write('    <input type="hidden" name="ie" value="UTF-8">');
                document.write('    <input type="text" name="q" size="21">');
                document.write('    <input type="submit" name="sa" value="Search">');
                document.write('  </div>');
                document.write('</form>');
              </script>-->
</div></div>
<div class="trails"><div class="trail">
<a href="https://help.ubuntu.com/18.04" class="trail">Ubuntu 18.04</a> » <a class="trail" href="../index.html" title="Ubuntu Server Guide">Ubuntu Server Guide</a> » <a class="trail" href="email-services.html" title="Email Services">Email Services</a> » </div></div>
<div id="cwt-content" class="clearfix content-area"><div id="page">
<div id="content">
<div class="links nextlinks">
<a class="nextlinks-prev" href="email-services.html" title="Email Services">Previous</a><a class="nextlinks-next" href="exim4.html" title="Exim4">Next</a>
</div>
<div class="hgroup"><h1 class="title">Postfix</h1></div>
<div class="region">
<div class="contents">
<p class="para">
            <span class="app application">Postfix</span> is the default Mail Transfer Agent (MTA) in Ubuntu. It
            attempts to be fast and easy to administer and secure. It is
            compatible with the MTA <span class="app application">sendmail</span>. This section explains how
            to install and configure <span class="app application">postfix</span>. It also explains how to
            set it up as an SMTP server using a secure connection (for sending emails securely).
          </p>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
            <p class="para">
            This guide does not cover setting up Postfix <span class="em emphasis">Virtual Domains</span>, for information
            on Virtual Domains and other advanced configurations see <a class="xref" href="postfix.html#postfix-references" title="References">References</a>.
            </p>
          </div></div></div></div>
</div>
<div class="links sectionlinks" role="navigation"><ul>
<li class="links"><a class="xref" href="postfix.html#postfix-installation" title="Installation">Installation</a></li>
<li class="links"><a class="xref" href="postfix.html#postfix-configuration" title="Basic Configuration">Basic Configuration</a></li>
<li class="links"><a class="xref" href="postfix.html#postfix-smtp-authentication" title="SMTP Authentication">SMTP Authentication</a></li>
<li class="links"><a class="xref" href="postfix.html#postfix-sasl" title="Configuring SASL">Configuring SASL</a></li>
<li class="links"><a class="xref" href="postfix.html#mail-stack-delivery" title="Mail-Stack Delivery">Mail-Stack Delivery</a></li>
<li class="links"><a class="xref" href="postfix.html#postfix-testing" title="Testing">Testing</a></li>
<li class="links"><a class="xref" href="postfix.html#postfix-troubleshooting" title="Troubleshooting">Troubleshooting</a></li>
</ul></div>
<div class="sect2 sect" id="postfix-installation"><div class="inner">
<div class="hgroup"><h2 class="title">Installation</h2></div>
<div class="region"><div class="contents">
<p class="para">
            To install <span class="app application">postfix</span> run the following command:
	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo apt install postfix</span>
</pre></div>
<p class="para">
	    Simply press return when the installation process asks questions, the configuration will be done in greater detail in the next stage.
            </p>
</div></div>
</div></div>
<div class="sect2 sect" id="postfix-configuration"><div class="inner">
<div class="hgroup"><h2 class="title">Basic Configuration</h2></div>
<div class="region"><div class="contents">
<p class="para">
            To configure <span class="app application">postfix</span>, run the following command:
	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo dpkg-reconfigure postfix</span>
</pre></div>
<p class="para">
            The user interface will be displayed. On each screen, select the following
            values:
            <div class="list itemizedlist"><ul class="list itemizedlist compact">
<li class="list itemizedlist"><p class="para">Internet Site</p></li>
<li class="list itemizedlist"><p class="para">mail.example.com</p></li>
<li class="list itemizedlist"><p class="para">steve</p></li>
<li class="list itemizedlist"><p class="para">mail.example.com, localhost.localdomain, localhost</p></li>
<li class="list itemizedlist"><p class="para">No</p></li>
<li class="list itemizedlist"><p class="para">127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 192.168.0.0/24</p></li>
<li class="list itemizedlist"><p class="para">0</p></li>
<li class="list itemizedlist"><p class="para">+</p></li>
<li class="list itemizedlist"><p class="para">all</p></li>
</ul></div>
            </p>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
            <p class="para">
            Replace mail.example.com with the domain for which you'll accept email, 192.168.0.0/24 with the actual network and class 
	    range of your mail server, and steve with the appropriate username.
            </p>
            </div></div></div></div>
<p class="para">
            Now is a good time to decide which mailbox format you want to use.  By default 
            Postfix will use  <span class="em em-bold emphasis">mbox</span> for the mailbox format.
            Rather than editing the configuration file directly, 
	    you can use the <span class="cmd command">postconf</span> command to configure
            all <span class="app application">postfix</span> parameters.  The
            configuration parameters will be stored in
            <span class="file filename">/etc/postfix/main.cf</span> file. Later if you
            wish to re-configure a particular parameter, you can either
            run the command or change it manually in the file.
            </p>
<p class="para">
            To configure the mailbox format for <span class="em em-bold emphasis">Maildir:</span>
            </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo postconf -e 'home_mailbox = Maildir/'</span>
</pre></div>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
            <p class="para">
            This will place new mail in /home/<span class="em emphasis">username</span>/Maildir so 
            you will need to configure your Mail Delivery Agent (MDA) to use the same path.
            </p>
            </div></div></div></div>
</div></div>
</div></div>
<div class="sect2 sect" id="postfix-smtp-authentication"><div class="inner">
<div class="hgroup"><h2 class="title">SMTP Authentication</h2></div>
<div class="region"><div class="contents">
<p class="para">
	    SMTP-AUTH allows a client to identify itself through an authentication mechanism (SASL).
	    Transport Layer Security (TLS) should be used to encrypt the authentication process.
	    Once authenticated the SMTP server will allow the client to relay mail.  
            </p>
<div class="steps"><div class="inner"><ol class="steps">
<li class="steps">
     	         <p class="para">
                 Configure Postfix for SMTP-AUTH using SASL (Dovecot SASL):
		 </p>
<div class="screen"><pre class="contents ">sudo postconf -e 'smtpd_sasl_type = dovecot'
sudo postconf -e 'smtpd_sasl_path = private/auth'
sudo postconf -e 'smtpd_sasl_local_domain ='
sudo postconf -e 'smtpd_sasl_security_options = noanonymous'
sudo postconf -e 'broken_sasl_auth_clients = yes'
sudo postconf -e 'smtpd_sasl_auth_enable = yes'
sudo postconf -e 'smtpd_recipient_restrictions = \
permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination'
</pre></div>
	        <div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
		<p class="para">
		The <span class="em emphasis">smtpd_sasl_path</span> configuration is a path relative to the Postfix queue directory.
	        </p>
		</div></div></div></div>
		</li>
<li class="steps">
                <p class="para">
                Next, generate or obtain a digital certificate for TLS. See <a class="xref" href="certificates-and-security.html" title="Certificates">Certificates</a> for details.
                This example also uses a Certificate Authority (CA).  For information on generating a CA certificate see
                <a class="xref" href="certificates-and-security.html#certificate-authority" title="Certification Authority">Certification Authority</a>.
	        </p>
		<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
                <p class="para">
                MUAs connecting to your mail server via TLS will need to recognize the certificate used for TLS.  This can either
                be done using a certificate from a commercial CA or with a self-signed certificate that users manually install/accept.  
                For MTA to MTA TLS certficates are never validated without advance agreement from the affected organizations.  For MTA
                to MTA TLS, unless local policy requires it, there is no reason not to use a self-signed certificate.  Refer to 
		<a class="xref" href="certificates-and-security.html#creating-a-self-signed-certificate" title="Creating a Self-Signed Certificate">Creating a Self-Signed Certificate</a> for more details.
                </p>
                </div></div></div></div>
		</li>
<li class="steps">
                <p class="para">
                Once you have a certificate, configure Postfix to provide TLS encryption for both incoming and outgoing mail:
                </p>
<div class="screen"><pre class="contents ">sudo postconf -e 'smtp_tls_security_level = may'
sudo postconf -e 'smtpd_tls_security_level = may'
sudo postconf -e 'smtp_tls_note_starttls_offer = yes'
sudo postconf -e 'smtpd_tls_key_file = /etc/ssl/private/server.key'
sudo postconf -e 'smtpd_tls_cert_file = /etc/ssl/certs/server.crt'
sudo postconf -e 'smtpd_tls_loglevel = 1'
sudo postconf -e 'smtpd_tls_received_header = yes'
sudo postconf -e 'myhostname = mail.example.com'
</pre></div>
		</li>
<li class="steps">
                  <p class="para">
                  If you are using your own <span class="em emphasis">Certificate Authority</span> to sign the certificate enter:
                  </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo postconf -e 'smtpd_tls_CAfile = /etc/ssl/certs/cacert.pem'</span>
</pre></div>

                  <p class="para">
                  Again, for more details about certificates see <a class="xref" href="certificates-and-security.html" title="Certificates">Certificates</a>.
                  </p>
                </li>
</ol></div></div>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
            <p class="para">
            After running all the commands, <span class="app application">Postfix</span> is configured for SMTP-AUTH 
	    and a self-signed certificate has been created for TLS encryption.
            </p>
            </div></div></div></div>
<p class="para">
            Now, the file <span class="file filename">/etc/postfix/main.cf</span> should look like this:
	    </p>
<div class="code"><pre class="contents "># See /usr/share/postfix/main.cf.dist for a commented, more complete
# version

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

myhostname = server1.example.com
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = server1.example.com, localhost.example.com, localhost
relayhost =
mynetworks = 127.0.0.0/8
mailbox_command = procmail -a "$EXTENSION"
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
smtpd_sasl_local_domain =
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions =
permit_sasl_authenticated,permit_mynetworks,reject _unauth_destination
smtpd_tls_auth_only = no
smtp_tls_security_level = may
smtpd_tls_security_level = may
smtp_tls_note_starttls_offer = yes
smtpd_tls_key_file = /etc/ssl/private/smtpd.key
smtpd_tls_cert_file = /etc/ssl/certs/smtpd.crt
smtpd_tls_CAfile = /etc/ssl/certs/cacert.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
</pre></div>
<p class="para">
            The postfix initial configuration is complete. Run
            the following command to restart the postfix daemon:
	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo systemctl restart postfix.service</span>
</pre></div>
<p class="para">
            <span class="app application">Postfix</span> supports SMTP-AUTH as defined in
            <a href="http://www.ietf.org/rfc/rfc2554.txt" class="ulink" title="http://www.ietf.org/rfc/rfc2554.txt">RFC2554</a>.
            It is based on <a href="http://www.ietf.org/rfc/rfc2222.txt" class="ulink" title="http://www.ietf.org/rfc/rfc2222.txt">SASL</a>. However it is still necessary 
	    to set up SASL authentication before you can use SMTP-AUTH.
            </p>
</div></div>
</div></div>
<div class="sect2 sect" id="postfix-sasl"><div class="inner">
<div class="hgroup"><h2 class="title">Configuring SASL</h2></div>
<div class="region"><div class="contents">
<p class="para">	              
	    Postfix supports two SASL implementations Cyrus SASL and Dovecot SASL.  To enable Dovecot SASL 	    
	    the <span class="app application">dovecot-core</span> package will need to be installed.  From a terminal prompt
	    enter the following:
	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo apt install dovecot-core</span>
</pre></div>
<p class="para">
 	    Next you will need to edit <span class="file filename">/etc/dovecot/conf.d/10-master.conf</span>.  Change the following:
	    </p>
<div class="code"><pre class="contents ">service auth {
  # auth_socket_path points to this userdb socket by default. It's typically
  # used by dovecot-lda, doveadm, possibly imap process, etc. Its default
  # permissions make it readable only by root, but you may need to relax these
  # permissions. Users that have access to this socket are able to get a list
  # of all usernames and get results of everyone's userdb lookups.
  unix_listener auth-userdb {
    #mode = 0600
    #user = 
    #group = 
  }

  # Postfix smtp-auth
  unix_listener /var/spool/postfix/private/auth {
    mode = 0660
    user = postfix
    group = postfix
  }
</pre></div>
<p class="para">
            In order to let <span class="app application">Outlook</span> clients use SMTP-AUTH, in the <span class="em emphasis">authentication mechanisms</span> 
            section of /etc/dovecot/conf.d/10-auth.conf change this line:
            </p>
<div class="code"><pre class="contents ">auth_mechanisms = plain
</pre></div>
<p class="para">
           To this:
           </p>
<div class="code"><pre class="contents ">auth_mechanisms = plain login
</pre></div>
<p class="para">
	    Once you have <span class="app application">Dovecot</span> configured restart it with:
	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo systemctl restart dovecot.service</span>
</pre></div>
</div></div>
</div></div>
<div class="sect2 sect" id="mail-stack-delivery"><div class="inner">
<div class="hgroup"><h2 class="title">Mail-Stack Delivery</h2></div>
<div class="region"><div class="contents">
<p class="para">
            Another option for configuring <span class="app application">Postfix</span> for SMTP-AUTH is using the
            <span class="app application">mail-stack-delivery</span> package (previously packaged as dovecot-postfix).
            This package will install 
            <span class="app application">Dovecot</span> and configure <span class="app application">Postfix</span> to use it
            for both SASL authentication and as a Mail Delivery Agent (MDA).
            </p>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
              <p class="para">
              You may or may not want to run IMAP, IMAPS, POP3, or POP3S on your mail server.  For example,
              if you are configuring your server to be a mail gateway, spam/virus filter, etc.  If this is
              the case it may be easier to use the above commands to configure Postfix for SMTP-AUTH than
              using <span class="app application">mail-stack-delivery</span>.
              </p>
            </div></div></div></div>
<p class="para">
            To install the package, from a terminal prompt enter:
            </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo apt install mail-stack-delivery</span>
</pre></div>
<p class="para">
            You should now have a working mail server, but there are a few options that you may wish to further customize.  For example, the
            package uses the certificate and key from the <span class="app application">ssl-cert</span> (self signed) package, and in a production environment you should
            use a certificate and key generated for the host.
            See <a class="xref" href="certificates-and-security.html" title="Certificates">Certificates</a> for more details.
            </p>
<p class="para">
                Once you have a customized certificate and key for the host, change the following options for postfix in <span class="file filename">/etc/postfix/main.cf</span> to match your new keys:
            </p>
<div class="code"><pre class="contents ">smtpd_tls_cert_file = #yourcertfile#
smtpd_tls_key_file = #yourkeyfile#
</pre></div>
<p class="para">
                And for <span class="app application">Dovecot</span> in <span class="file filename">/etc/dovecot/conf.d/10-ssl.conf</span>:
            </p>
<div class="code"><pre class="contents ">ssl_cert = &lt;#yourcertfile#
ssl_key = &lt;#yourkeyfile#
</pre></div>
<p class="para">
            Then restart Postfix:
            </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo systemctl restart postfix.service</span>
</pre></div>
</div></div>
</div></div>
<div class="sect2 sect" id="postfix-testing"><div class="inner">
<div class="hgroup"><h2 class="title">Testing</h2></div>
<div class="region"><div class="contents">
<p class="para">
            SMTP-AUTH configuration is complete. Now it is time to test the setup. 
	    </p>
<p class="para">
            To see if SMTP-AUTH and TLS work properly, run the following
            command:
            </p>
<div class="screen"><pre class="contents "><span class="cmd command">telnet mail.example.com 25</span>
</pre></div>
<p class="para">
            After you have established the connection to the postfix mail
            server, type:
            </p>
<div class="screen"><pre class="contents ">ehlo mail.example.com
</pre></div>
<p class="para">
          If you see the following lines among others, then everything
          is working perfectly. Type <span class="cmd command">quit</span> to exit.
          </p>
<div class="code"><pre class="contents ">250-STARTTLS
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250 8BITMIME
</pre></div>
</div></div>
</div></div>
<div class="sect2 sect" id="postfix-troubleshooting"><div class="inner">
<div class="hgroup"><h2 class="title">Troubleshooting</h2></div>
<div class="region">
<div class="contents"><p class="para">
	    This section introduces some common ways to determine the cause if problems arise.
	    </p></div>
<div class="sect3 sect" id="postfix-chroot"><div class="inner">
<div class="hgroup"><h3 class="title">Escaping chroot</h3></div>
<div class="region"><div class="contents">
<p class="para">
 	    The Ubuntu <span class="app application">postfix</span> package will by default install into a <span class="em emphasis">chroot</span> 
	    environment for security reasons.  This can add greater complexity when troubleshooting problems.
	    </p>
<p class="para">
          To turn off the chroot operation locate for the following line in the
          <span class="file filename">/etc/postfix/master.cf</span> configuration file:
          </p>
<div class="screen"><pre class="contents ">smtp      inet  n       -       -       -       -       smtpd
</pre></div>
<p class="para">
	  and modify it as follows:
          </p>
<div class="screen"><pre class="contents ">smtp      inet  n       -       n       -       -       smtpd
</pre></div>
<p class="para">
	  You will then need to restart Postfix to use the new configuration.  From a terminal prompt enter:
          </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo systemctl restart postfix.service</span>
</pre></div>
</div></div>
</div></div>
<div class="sect3 sect" id="postfix-smtps"><div class="inner">
<div class="hgroup"><h3 class="title">Smtps</h3></div>
<div class="region"><div class="contents">
<p class="para">
	    If you need smtps, edit <span class="file filename">/etc/postfix/master.cf</span> and uncomment the following line:
	  </p>
<div class="code"><pre class="contents ">smtps     inet  n       -       -       -       -       smtpd
  -o smtpd_tls_wrappermode=yes
  -o smtpd_sasl_auth_enable=yes
  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
  -o milter_macro_daemon_name=ORIGINATING
	  </pre></div>
</div></div>
</div></div>
<div class="sect3 sect" id="postfix-logs"><div class="inner">
<div class="hgroup"><h3 class="title">Log Files</h3></div>
<div class="region"><div class="contents">
<p class="para">
	  <span class="app application">Postfix</span> sends all log messages to <span class="file filename">/var/log/mail.log</span>.
	  However error and warning messages can sometimes get lost in the normal log output so they are also logged to
          <span class="file filename">/var/log/mail.err</span> and <span class="file filename">/var/log/mail.warn</span> respectively.
          </p>
<p class="para">
 	  To see messages entered into the logs in real time you can use the <span class="app application">tail -f</span>
	  command:
	  </p>
<div class="screen"><pre class="contents "><span class="cmd command">tail -f /var/log/mail.err</span>
</pre></div>
<p class="para">
	The amount of detail that is recorded in the logs can be increased.  Below are some configuration options for increasing the log level
	for some of the areas covered above.
	</p>
<div class="list itemizedlist"><ul class="list itemizedlist compact">
<li class="list itemizedlist">
	    <p class="para">
	    To increase <span class="em emphasis">TLS</span> activity logging set the <span class="em emphasis">smtpd_tls_loglevel</span> option to a value from 1 to 4.
 	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo postconf -e 'smtpd_tls_loglevel = 4'</span>
</pre></div>
	  </li>
<li class="list itemizedlist">
	    <p class="para">
	    If you are having trouble sending or receiving mail from a specific domain you can add the domain to the <span class="em emphasis">debug_peer_list</span>
	    parameter.
 	    </p>
<div class="screen"><pre class="contents "><span class="cmd command">sudo postconf -e 'debug_peer_list = problem.domain'</span>
</pre></div>
	  </li>
<li class="list itemizedlist">
	    <p class="para">
	    You can increase the verbosity of any <span class="app application">Postfix</span> daemon process by editing the <span class="file filename">/etc/postfix/master.cf</span>
	    and adding a <span class="em emphasis">-v</span> after the entry.  For example edit the <span class="em emphasis">smtp</span> entry:
 	    </p>
<div class="code"><pre class="contents ">smtp      unix  -       -       -       -       -       smtp -v
</pre></div>	    
	  </li>
</ul></div>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
	  <p class="para">
	  It is important to note that after making one of the logging changes above the <span class="app application">Postfix</span> process will need to be reloaded
	  in order to recognize the new configuration: <span class="cmd command">sudo systemctl reload postfix.service</span>
	  </p>
	</div></div></div></div>
<div class="list itemizedlist"><ul class="list itemizedlist compact"><li class="list itemizedlist">
	    <p class="para">
   	    To increase the amount of information logged when troubleshooting <span class="em emphasis">SASL</span> issues you can set the following options in 
	    <span class="file filename">/etc/dovecot/conf.d/10-logging.conf</span>
	    </p>
<div class="code"><pre class="contents ">auth_debug=yes
auth_debug_passwords=yes
</pre></div>
	  </li></ul></div>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
	  <p class="para">
	  Just like <span class="app application">Postfix</span> if you change a <span class="app application">Dovecot</span> configuration the process will need to be
	  reloaded: <span class="cmd command">sudo systemctl reload dovecot.service</span>.
	  </p>
	</div></div></div></div>
<div class="note" title="Note"><div class="inner"><div class="region"><div class="contents">
	  <p class="para">
          Some of the options above can drastically increase the amount of information sent to the log files.  Remember to return the log level 
	  back to normal after you have corrected the problem.  Then reload the appropriate daemon for the new configuration to take affect.
	  </p>
	</div></div></div></div>
</div></div>
</div></div>
<div class="sect3 sect" id="postfix-references"><div class="inner">
<div class="hgroup"><h3 class="title">References</h3></div>
<div class="region"><div class="contents">
<p class="para">
	  Administering a <span class="app application">Postfix</span> server can be a very complicated task.  At some point you may
	  need to turn to the Ubuntu community for more experienced help.
	  </p>
<p class="para">
	  A great place to ask for <span class="app application">Postfix</span> assistance, and get involved with the Ubuntu Server community,
	  is the <span class="em emphasis">#ubuntu-server</span>  IRC channel on  <a href="http://freenode.net" class="ulink" title="http://freenode.net">freenode</a>.  You 
	  can also post a message to one of the <a href="http://www.ubuntu.com/support/community/webforums" class="ulink" title="http://www.ubuntu.com/support/community/webforums">Web Forums</a>.
          </p>
<p class="para">
	  For in depth <span class="app application">Postfix</span> information Ubuntu developers highly recommend:
	  <a href="http://www.postfix-book.com/" class="ulink" title="http://www.postfix-book.com/">The Book of Postfix</a>.
	  </p>
<p class="para">
	  Finally, the <a href="http://www.postfix.org/documentation.html" class="ulink" title="http://www.postfix.org/documentation.html">Postfix</a> website also has great documentation on all
	  the different configuration options available.
	  </p>
<p class="para">
      Also, the <a href="https://help.ubuntu.com/community/Postfix" class="ulink" title="https://help.ubuntu.com/community/Postfix">Ubuntu Wiki Postfix</a> page has more information.
      </p>
</div></div>
</div></div>
</div>
</div></div>
</div>
<div class="links nextlinks">
<a class="nextlinks-prev" href="email-services.html" title="Email Services">Previous</a><a class="nextlinks-next" href="exim4.html" title="Exim4">Next</a>
</div>
<div class="clear"></div>
</div>
<div id="pagebottom"></div>
</div></div>
</div>
<div id="footer"><p>The material in this document is available under a free license, see <a href="https://help.ubuntu.com/legal.html">Legal</a> for details.<br>
          For information on contributing see the <a href="https://wiki.ubuntu.com/DocumentationTeam">Ubuntu Documentation Team wiki page</a>.
          To report errors in this serverguide documentation, <a href="https://bugs.launchpad.net/serverguide">file a bug report</a>.</p></div>
</div>
</body>
</html>
